package com.example.entity;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.*;

//部门表
@Data
@AllArgsConstructor
@NoArgsConstructor
@Entity
@Table
public class Department {

    @Column(name = "department_id",length = 11,nullable = false)
    private Integer id;

    @Column(name = "user_id",length = 11,nullable = false)
    private Integer userId;

    @Column(name = "department_name",length = 50)
    private String name;

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Integer idd;

}
